package com.ruoyi.pack.domain;

import java.util.Date;
import java.util.List;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import com.ruoyi.pack.domain.dto.ProjectMaterialOperationDto;
import com.ruoyi.pack.domain.dto.ProjectWarehouseOperationDto;

/**
 * 项目表 pack_project
 * 
 * @author ruoyi
 */
public class PackProject extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 项目ID */
    private Long projectId;

    /** 项目编码 */
    @Excel(name = "项目编码")
    @NotBlank(message = "项目编码不能为空")
    @Size(min = 0, max = 50, message = "项目编码长度不能超过50个字符")
    private String projectCode;

    /** 项目名称 */
    @Excel(name = "项目名称")
    @NotBlank(message = "项目名称不能为空")
    @Size(min = 0, max = 100, message = "项目名称长度不能超过100个字符")
    private String projectName;

    /** 项目所属公司ID */
    @NotNull(message = "项目所属公司不能为空")
    private Long companyId;

    /** 器具货主公司ID */
    @NotNull(message = "器具货主公司不能为空")
    private Long containerOwnerId;

    /** 物料货主公司ID */
    @NotNull(message = "物料货主公司不能为空")
    private Long materialOwnerId;

    /** 业务起始日期 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "业务起始日期", width = 30, dateFormat = "yyyy-MM-dd")
    @NotNull(message = "业务起始日期不能为空")
    private Date startDate;

    /** 业务结束日期 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "业务结束日期", width = 30, dateFormat = "yyyy-MM-dd")
    private Date endDate;

    /** 项目状态（1-进行中 2-已完成 3-已暂停） */
    @Excel(name = "项目状态", readConverterExp = "1=进行中,2=已完成,3=已暂停")
    private String projectStatus;

    /** 所属公司名称（用于导出） */
    @Excel(name = "所属公司")
    private String companyName;

    /** 器具货主公司名称（用于导出） */
    @Excel(name = "器具货主公司")
    private String containerOwnerName;

    /** 物料货主公司名称（用于导出） */
    @Excel(name = "物料货主公司")
    private String materialOwnerName;

    /** 项目物料列表（用于新增项目时批量添加物料） */
    private List<PackProjectMaterial> materialList;

    /** 项目仓库权限列表（用于新增项目时批量添加仓库权限） */
    private List<PackProjectWarehouseOperation> warehouseOperationList;

    /** 物料操作列表（用于修改项目时批量处理物料） */
    private List<ProjectMaterialOperationDto> materialOperations;

    /** 仓库权限操作列表（用于修改项目时批量处理仓库权限） */
    private List<ProjectWarehouseOperationDto> warehouseOperations;

    /** 物料数量（查询时统计用） */
    private Integer materialCount;

    /** 仓库数量（查询时统计用） */
    private Integer warehouseCount;

    public Long getProjectId()
    {
        return projectId;
    }

    public void setProjectId(Long projectId)
    {
        this.projectId = projectId;
    }

    public String getProjectCode()
    {
        return projectCode;
    }

    public void setProjectCode(String projectCode)
    {
        this.projectCode = projectCode;
    }

    public String getProjectName()
    {
        return projectName;
    }

    public void setProjectName(String projectName)
    {
        this.projectName = projectName;
    }

    public Long getCompanyId()
    {
        return companyId;
    }

    public void setCompanyId(Long companyId)
    {
        this.companyId = companyId;
    }

    public Long getContainerOwnerId()
    {
        return containerOwnerId;
    }

    public void setContainerOwnerId(Long containerOwnerId)
    {
        this.containerOwnerId = containerOwnerId;
    }

    public Long getMaterialOwnerId()
    {
        return materialOwnerId;
    }

    public void setMaterialOwnerId(Long materialOwnerId)
    {
        this.materialOwnerId = materialOwnerId;
    }

    public Date getStartDate()
    {
        return startDate;
    }

    public void setStartDate(Date startDate)
    {
        this.startDate = startDate;
    }

    public Date getEndDate()
    {
        return endDate;
    }

    public void setEndDate(Date endDate)
    {
        this.endDate = endDate;
    }

    public String getProjectStatus()
    {
        return projectStatus;
    }

    public void setProjectStatus(String projectStatus)
    {
        this.projectStatus = projectStatus;
    }

    public String getCompanyName()
    {
        return companyName;
    }

    public void setCompanyName(String companyName)
    {
        this.companyName = companyName;
    }

    public String getContainerOwnerName()
    {
        return containerOwnerName;
    }

    public void setContainerOwnerName(String containerOwnerName)
    {
        this.containerOwnerName = containerOwnerName;
    }

    public String getMaterialOwnerName()
    {
        return materialOwnerName;
    }

    public void setMaterialOwnerName(String materialOwnerName)
    {
        this.materialOwnerName = materialOwnerName;
    }

    public List<PackProjectMaterial> getMaterialList()
    {
        return materialList;
    }

    public void setMaterialList(List<PackProjectMaterial> materialList)
    {
        this.materialList = materialList;
    }

    public List<PackProjectWarehouseOperation> getWarehouseOperationList()
    {
        return warehouseOperationList;
    }

    public void setWarehouseOperationList(List<PackProjectWarehouseOperation> warehouseOperationList)
    {
        this.warehouseOperationList = warehouseOperationList;
    }

    public List<ProjectMaterialOperationDto> getMaterialOperations()
    {
        return materialOperations;
    }

    public void setMaterialOperations(List<ProjectMaterialOperationDto> materialOperations)
    {
        this.materialOperations = materialOperations;
    }

    public List<ProjectWarehouseOperationDto> getWarehouseOperations()
    {
        return warehouseOperations;
    }

    public void setWarehouseOperations(List<ProjectWarehouseOperationDto> warehouseOperations)
    {
        this.warehouseOperations = warehouseOperations;
    }

    public Integer getMaterialCount()
    {
        return materialCount;
    }

    public void setMaterialCount(Integer materialCount)
    {
        this.materialCount = materialCount;
    }

    public Integer getWarehouseCount()
    {
        return warehouseCount;
    }

    public void setWarehouseCount(Integer warehouseCount)
    {
        this.warehouseCount = warehouseCount;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("projectId", getProjectId())
            .append("projectCode", getProjectCode())
            .append("projectName", getProjectName())
            .append("companyId", getCompanyId())
            .append("containerOwnerId", getContainerOwnerId())
            .append("materialOwnerId", getMaterialOwnerId())
            .append("startDate", getStartDate())
            .append("endDate", getEndDate())
            .append("projectStatus", getProjectStatus())
            .append("remark", getRemark())
            .append("createBy", getCreateBy())
            .append("createTime", getCreateTime())
            .append("updateBy", getUpdateBy())
            .append("updateTime", getUpdateTime())
            .toString();
    }
} 